VisitRecorder = {};
VisitRecorder.record = function(data) {
  var date = new Date();
  data.u = document.location.href;
  // data.w = screen.width
  // data.h = screen.height
  data.t = document.title
  data.n = date.getTime();
  if(document.referrer && document.referrer != "") {
    data.r = document.referrer;
  }
  $("body").append("<img class='visit-recorder' src='<%= record_visit_path %>?" + jQuery.param(data) + "' style='display:none;' />");
};
